import request, {postJson} from "@/apps/admin/utils/request";

const server = "/v1/admin";

// 获取管理员列表的接口，支持分页
export function getAdmins(page, size) {
    return request.get(`${server}/getAdmins`);
}

export function createAdmin(data) {
    return postJson(`${server}/createAdmin`, data);
}

export function updateAdmin(data) {
    return postJson(`${server}/updateAdmin`, data);
}

export function deleteAdmin(data) {
    return postJson(`${server}/deleteAdmin`, data);
}
